package com.wcl.demo.presenter;

import com.wcl.demo.model.ModelRegister;
import com.wcl.demo.model.modelinterface.ModelRegisterInterface;
import com.wcl.demo.presenter.presenterinterface.PresenterRegisterInterface;
import com.wcl.demo.ui.ViewInterface.ViewRegisterInterface;

import java.util.Map;

/**
 * Created by dllo on 15/11/20.
 */
public class RegisterPresenter extends BasePresenter<ViewRegisterInterface> implements PresenterRegisterInterface {
    private ViewRegisterInterface viewRegisterInterface;
    private ModelRegisterInterface modelRegisterInterface;


    public RegisterPresenter(ViewRegisterInterface viewRegisterInterface) {
        this.viewRegisterInterface = viewRegisterInterface;
        modelRegisterInterface = new ModelRegister();
    }
    public void startRegister(Map<String, String> map){
        modelRegisterInterface.recvieveResult(map, this);
    }

    @Override
    public void sendResult(String str) {
        viewRegisterInterface.showResult(str);
    }
}
